package com.ep.factory;
/**
 * 工厂类
 * @author Sunxg
 */
public class BeanFactory {
	/**根据类的字节码路径 实例化对象*/
	public static Object newInstanceBean(String className){
		Class clazz;
		Object obj=null;
		try {
			clazz = Class.forName(className);
			obj = clazz.newInstance();
		} catch (Exception e) {
			e.printStackTrace();
		}
		return obj;
	}
}
